using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.SessionState;
using SAY.Web.Security.QueryStringManagerModule;

namespace QueryStringManagerTest
{
    public class Global : System.Web.HttpApplication
    {
        protected void Application_Start(object sender, EventArgs e)
        {
            QueryStringManager.Instance.RegisterPage("~/Default.aspx", QueryStringProtections.Strict, EncryptionTypes.Encrypted);
            QueryStringManager.Instance.RegisterParameter("~/Default.aspx", new QueryStringItem("", "X", typeof(int), true));
            QueryStringManager.Instance.RegisterParameter("~/Default.aspx", new QueryStringItem("", "Y", typeof(DateTime), true));
        }

        protected void Application_BeginRequest(object sender, EventArgs e)
        {
            QueryStringManager.Instance.CheckQueryString(HttpContext.Current);      
        }

        protected void Application_End(object sender, EventArgs e)
        {
            
        }
    }
}